Welcome to the Medication Dosage Calculator
Created on 2025-09-17
- Accepts weight in pounds
- Adjusts for age, gender, frequency, and concentration
- Calculates total daily dose, dose per administration, and volume per dose
- Displays results and a visual bar chart
- Clinically relevant and beginner-friendly
- Helps users understand weight-based dosing
- Can be expanded for pediatric logic or max dose limits
- Useful for students, clinicians, and caregivers
# Sample dosage calculation
weight_lbs <- 154
weight_kg <- weight_lbs * 0.453592
dose_mg <- weight_kg * 15 # Paracetamol
dose_mg
## [1] 1047.798
## Sample Dosage vs. Weight Plot
weight_lbs <- seq(50, 250, by = 10)
weight_kg <- weight_lbs * 0.453592
dose_mg <- weight_kg * 15 # Paracetamol
plot(weight_lbs, dose_mg, type = "l", col = "blue", lwd = 2,
xlab = "Weight (lbs)", ylab = "Dosage (mg)",
main = "Paracetamol Dosage by Weight")
## Interactive Dosage Plot
library(plotly)
## Loading required package: ggplot2
##
## Attaching package: 'plotly'
## The following object is masked from 'package:ggplot2':
##
## last_plot
## The following object is masked from 'package:stats':
##
## filter
## The following object is masked from 'package:graphics':
##
## layout
plot_ly(x = weight_lbs, y = dose_mg, type = 'scatter', mode = 'lines',
line = list(color = 'green')) %>%
layout(title = "Interactive Dosage Curve",
xaxis = list(title = "Weight (lbs)"),
yaxis = list(title = "Dosage (mg)"))
Ready to explore the Medication Dosage Calculator? Use the links below to interact with the app, view the source code, and revisit this presentation.
🌐 Live App: https://emajor.shinyapps.io/MedDosageApp/
💻 GitHub Repo: https://github.com/Emajor1/MedDosage-App
Thank you for viewing! This app was designed to make clinical dosing safer, simpler, and more accessible